package com.yan.demo.loopdemo;

public class Test12 {
    public static void main(String[] args) {
        // 定义一元纸币的变量,和五角银币的数量变量
        int i,j;
        for(i = 0 ; i <= 10 ; i++){ // 1元纸币从换0张到换10全换1元纸币
            j = (int)((10-i) / 0.5);
            System.out.println("换一元纸币" + i + "张," + "五角纸币" + j + "个");
        }
    }
}
